<template>
    <div v-bind="$attrs">
        <Select v-model:value="monthSelect" style="width:100px;float: right; position: relative; top: 2px;"
            size="small">
            <SelectOption v-for="(item, index) in MonthBimonthly" :key="index" :value="item.value">{{ item.label }}
            </SelectOption>
        </Select>
    </div>
</template>
<script lang="ts" setup>
import { ref,watch } from 'vue';
import { Select } from 'ant-design-vue';
import { MonthBimonthly } from '../enum/index';
const SelectOption = Select.Option;
const props = defineProps<{
    month: number
}>()
const emits = defineEmits(['selectMonth']);
const { month } = props;
const monthSelect = ref<number>(month); //默认选择单月

watch(monthSelect,(newValue,oldValue)=>{
    emits("selectMonth",newValue)
})
</script>